package net.goutalk.glcs.module.erpModel.caseErpSale.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;

import com.fasterxml.jackson.annotation.JsonFormat;
import net.goutalk.glcs.common.model.base.AuditEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * <p>
 * 销售订单详情【case_erp_sale_detail】
 * </p>
 *
 * @author hnyyzy
 * @since 2023-07-17
 */
@TableName("case_erp_sale_detail")
@ApiModel(value = "CaseErpSaleDetail对象", description = "销售订单详情【case_erp_sale_detail】")
@Data
@EqualsAndHashCode(callSuper = false)
public class CaseErpSaleDetail extends AuditEntity implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty("主键")
    private Long id;

    @ApiModelProperty("订单外键Id(case_erp_sale)")
    private Long saleId;

    @ApiModelProperty("物料编码")
    private String code;

    @ApiModelProperty("物料名称")
    private String name;

    @ApiModelProperty("规格型号")
    private String model;

    @ApiModelProperty("单位")
    private String unitName;

    @ApiModelProperty("单价")
    private BigDecimal price;

    @ApiModelProperty("数量")
    private BigDecimal count;

    @ApiModelProperty("折扣")
    private BigDecimal discount;

    @ApiModelProperty("税率")
    private BigDecimal taxRate;

    @ApiModelProperty("税费")
    private BigDecimal taxBreak;

    @ApiModelProperty("税后金额")
    private BigDecimal afterTaxAmount;

    @ApiModelProperty("交付日期")
    @JsonFormat(pattern = "yyyy-MM-dd")
    private LocalDateTime deliveryDate;

    @ApiModelProperty("已入库数量")
    private BigDecimal inStoreCount;

    @ApiModelProperty("未入库数量")
    private BigDecimal noInStoreCount;

    @ApiModelProperty("退货数量")
    private BigDecimal returnCount;

    @ApiModelProperty("计划生产数量")
    private BigDecimal planCount;

    @ApiModelProperty("备注")
    private String remark;
}
